为何说 Firefox 仍落后 Google Chrome 数年
Firefox has a problem. It has fallen behind, with development stalled on the most crucial, most difficult problems. Many of the most significant improvements in Firefox over the past few years have simply been copying changes made in Chrome.
Firefox 出现了一个大问题。它在解决浏览器最关键、最困难问题的开发上落于人后。在过去几年当中 Firefox 许多最重要的改进都仅仅是重复 Chrome 所走的路。
We wish Firefox was better, but the reality is that it’s still not as good as Chrome. With so many former Firefox developers now working on Chrome at Google, perhaps it makes sense that the innovation has been happening in Chrome, not Firefox.
我们都希望 Firefox 变得更好,但实际上它仍不如 Chrome。如今有许多以前的 Firefox 开发者都在 Google 开发 Chrome,以致于更像是 Chrome 在不断创新,而不是 Firefox。
CPUs are gaining more and more cores, becoming capable of doing more work in parallel. Single-core CPUs have become unheard of, and even the lowest-power computers have dual-core CPUs at the least. The future is an ever-increasing amount of CPU cores, and computer programs will have to become capable of doing more work in parallel to take advantage of all this processing power.
随着核心数不断增多,CPU 已经能够并行执行更多任务。如今市面上已经找不到单核 CPU,即便是最低端的计算机都至少拥有双核 CPU。所以未来的趋势是拥有越来越多的 CPU 核心,计算机程序可以利用这些处理器性能并行执行更多任务。
Chrome deals with this by having a multi-process architecture. Every website you have open runs in its own process. Background processes, like extensions and apps doing work in the background, run in their own process. Browser plug-ins also run in their own process. Crucially, Chrome’s user interface runs in its own process, as well.
Chrome 为此开发了多进程架构。所有您打开的网站都在各自的进程中运行,像是扩展、应用会使用各自的进程在后台运行。浏览器插件也在单独的进程运行。最关键的是 Chrome 的用户界面也使用单独的进程。
if you have a modern multi-core CPU, Chrome will use it intelligently and perform well, dividing work up between CPUs. It can do many things at once and Chrome’s interface should never stutter and hiccup as pages load in the background.
如果您拥有一个现代的多核 CPU,Chrome 会智能且良好地将所有任务分配到不同 CPU 当中执行。这样 Chrome 可以同时做很多事情,在后台加载网页时浏览器界面也不会出现卡顿延迟。
Firefox is another matter. Firefox uses a single-process architecture, although plugins now run in a separate process. If you open five browser tabs, the main Firefox process has to load and render them as well as handle the Firefox user interface, so the browser will be nowhere near as responsive as Chrome. If one of the pages crashes, it will bring the whole browser down with it.
Firefox 则是另外一回事。它主要使用单进程架构,仅仅将插件置于单独的进程中运行。如果您同时打开五个标签页,Firefox 的主进程不仅要加载渲染这些标签页,同时还要处理用户界面。这样 Firefox 界面的反应就远不及 Chrome 那么快。如果一个页面崩溃,它会导致整个浏览器都随之崩溃。
This is still extremely noticeable — on a powerful Intel Core i7 CPU, Chrome performs perfectly yet Firefox’s interface stutters and slows down as multiple pages load, at least in my experience. It just isn’t as smooth, and it’s because of Firefox’s dated architecture.
在某些情况下这种差别尤为显著,试想同是使用 Intel Core i7 CPU 加载页面时,Chrome 表现完美,而 Firefox 的界面则反应迟钝,至少我是这么感受的。Firefox 流畅度不够都是由于它那过时的架构。
Mozilla was working on a solution for this. It was called Electrolysis, development began in 2009, and it was a project to make Firefox into a proper multi-process browser. Electrolysis was “put on hold for the foreseeable future” in 2011, with Mozilla stating that “Electrolysis is a huge undertaking” and that they would be pursuing “a number of smaller initiatives” to improve browser responsiveness in the short term.
对此 Mozilla 也在研究相应的解决方案,即 Electrolysis 项目。该项目可以追溯到 2009 年,目的是将 Firefox 变成一个可靠的多进程浏览器。但到了 2011 年 Electrolysis 项目“在可预见的未来无限搁置” ,Mozilla 的说法是 ”Electrolysis 是一个巨大的工程”,他们要在短期内采用“一系列微创新”来改善浏览器响应速度。
Mozilla recently restarted the Electrolysis project in May 2013, so if we’re lucky we’ll see a multi-process Firefox at some point. Even Internet Explorer has multi-process features as of Internet Explorer 8, so Firefox is way behind — and just now starting the hard work of catching up after stopping the project in 2011.
Mozilla 最近于 2013 年 5 月又重启了 Electrolysis 项目,所以如果幸运的话,我们可以在未来某个时候见到多进程的 Firefox。即便是 Internet Explorer 也从 IE8 开始采用多进程的特性,所以说 Firefox 已经落后了,好在这个在 2011 年停止的项目又重新出发并奋起直追。
落后 Chrome:4.7 年,并且仍在继续
Chrome and Internet Explorer use a modern Windows feature called “low integrity mode” or “protected mode” to run browser processes with as few user permissions as possible. If a browser vulnerability was discovered and exploited in Chrome or IE, the exploiter would also have to use some sort of additional vulnerability to escape the security sandbox and gain access to the rest of the system.
Chrome 和 Internet Explorer 都无一例外地在 Windows 系统中采用了一个被称为“低完整性模式”或“保护模式”的特性,该模式尽可能地降低用户权限来运行浏览器进程。如果有人发现了某个浏览器漏洞并打算将其应用到 Chrome 或 IE,他还需要使用一些额外漏洞来绕过安全沙盒来实现对系统剩余区域的访问。
This feature has been around since Windows Vista, which was released over six years ago. However, Mozilla is still working on the “low rights Firefox” feature and there’s no time-frame for when sandboxing features will roll out to users. Sandboxing isn’t a cure-all, but it’s an important security feature found in other modern browsers.
这项特性早在六年前发布的 Windows Vista 系统中就已经有了,但 Mozilla 仍在使用 “低权限 Firefox” 特性,而且也没有明确何时会采用沙盒技术。虽然沙盒技术不是万灵药,但却是现代浏览器均含有的一项重要安全特性。
Comments on Firefox’s bug tracker indicate that developers will be looking at sandboxing the Windows 8 Modern Firefox app, Firefox OS, and experimental Servo browser on OS X. There’s no indication that anyone is working on sandboxing the Windows desktop version of Firefox at the moment. That’s clearly the most popular, most vulnerable version of Firefox that needs the most protecting.
Firefox 相应 bug 跟踪的评论指出开发者计划在 Windows 8 Modern Firefox app、 Firefox OS 和在 OS X 处于试验阶段的 Servo 浏览器当中寻求对沙盒技术的支持,但目前没有任何消息表明 Firefox 的 Windows 桌面版本正在开发沙盒技术。很显然,这个最流行却最多漏洞的 Firefox 版本急需得到保护。
落后 Chrome:4.7年 ,并且仍在继续
Mozilla is adamant that web apps and web technologies will replace the need for desktop software and native mobile apps, offering a cross-platform future where HTML5 apps run on every platform.
Mozilla 坚定不移地表示网页应用和网页技术终将取代桌面软件和本地移动应用,因为前者拥有跨平台特性,任何 HTML5 应用都能在所有平台运行。
To this end, Mozilla wants to create its own web app store, known as the Firefox Marketplace. This feature is available in Firefox for Android and will be part of Firefox OS. Firefox OS is itself a mobile operating system that’s launching years after it should have — later than even Microsoft’s Windows Phone and BlackBerry’s BlackBerry 10, two mobile operating systems that have a long uphill fight ahead of them because they were launched so late.
为此 Mozilla 想要建立自己的应用商店,也就是熟知的 Firefox Marketplace。这项特性已经应用到了 Firefox 的安卓版本,未来也将成为 Firefox OS 的一部分。Firefox OS 是一个移动操作系统,但它多年后才姗姗来迟,甚至比微软的 Windows Phone 和黑莓的 BlackBerry 10 系统来的更晚,而这两个系统本身就因为太晚出现而需要长期与领先者竞争。
However, you can only use the Firefox Marketplace on Firefox for Android at the moment. Mozilla has been talking about releasing a Firefox Marketplace for the desktop for years, but they’ve decided to focus only on mobile for now. The desktop Firefox Marketplace will be released in the future. In the meantime, Chrome has had the Chrome Web Store for years. New Chrome packaged apps will soon extend the functionality of Chrome web apps, making more of a splash.
但目前您还只能在 Firefox 的安卓版本上使用 Firefox Marketplace。Mozilla 讨论发布桌面版 Fireofx 应用商店已经很多年了,但最终也只决定将精力放在移动平台,而计划在未来再发布桌面版的 Firefox 应用商店。相比之下,Chrome 的网上应用店已经存在好些年了。新的Chrome 封包应用也将很快会扩充 Chrome 网页应用的功能,从而更加引人注目。
Mozilla wants to be pushing web apps and open web technologies on the desktop, but they’re not doing it — Google is.
Mozilla 想要将网页应用和开放的网页技术推广到桌面版,但他们却无所作为,而这正是 Google 正在做的。
落后 Chrome: 2.5 年,并且仍在继续
Firefox has caught up in many ways over the years, but many of its changes have simply been copying the way Google Chrome works:
Firefox 在过去几年里已经从各方面奋起直追,但很多特性仅仅是简单地复制 Google Chrome:
Taken as a whole, it’s clear to see that Chrome has been leading the pack in browser innovation for years.
综上所述,很显然 Chrome 在浏览器创新方面已经领先了很多年。
We’re not just trying to attack Firefox here. It was once the best browser, and Mozilla deserves credit for eating into Internet Explorer 6′s market share, showing Microsoft that they could lose their place and forcing them to restart their halted Internet Explorer development. They also deserve credit for making the web more standardized, eliminating websites that say they’re “Designed for Internet Explorer.” This has allowed other browsers to step in — the most popular ones being Chrome and Safari. Firefox laid the groundwork, and Mozilla has been a tireless fighter for open standards.
我们在这里并不想试图攻击 Firefox。它曾经是最好的浏览器,Mozilla 在蚕食 Internet Explorer 6 市场份额方面值得称道,它让微软感到他们是有可能失去市场份额并迫使微软重启停滞的 IE 开发进程。在网页标准化,减少”专为 Internet Explorer 设计”的网站方面,Mozilla 也值得赞许。这为其他浏览器的前进开辟了道路,现在 Chrome 和 Safari 成为了最流行的浏览器。Firefox 为开放的标准化打下了坚实的基础,而 Mozilla 可以说是一名不知疲倦的斗士。
It’s good for the web to have Mozilla as a browser vendor that isn’t tied to a single large corporation, as Microsoft, Google, and Apple own the other top browsers. The fact that we have an open-source browser created by a non-profit organization only looking to make the web a better is great for the web.
作为一个浏览器开发商,Mozilla 独立于其他拥有顶尖浏览器的大型公司,如微软、Google 和苹果公司,这对互联网来说是一件好事。事实上,一个由非盈利性组织开发的开源浏览器,专注于让互联网变得更好的理念,这对于互联网来说可以用伟大来形容。
That’s why it’s a shame Mozilla has allowed Firefox to fall so far behind. Halting development on Electrolysis and still having not implemented sandboxing security features are signs that Mozilla hasn’t been prepared to knuckle-down and do the really hard low-level work to improve Firefox’s performance and security. Many of the other changes they’ve made have imitated changes made in Chrome much earlier.
这就是为什么说 Firefox 远远落后足以让 Mozilla 感到羞愧。停止开发 Electrolysis,尚未实现安全沙盒特性,这些都表明 Mozilla 还没准备好大干一场,真正地去做些底层工作来改善 Firefox 的性能和安全性。他们所作的许多改进仅仅是模仿 Chrome 早已实现的功能。
Firefox is still the best browser in some ways. For example, if you need the most powerful browser extension framework, Firefox has it. But we wish Firefox was more competitive in other ways. In 2013, a browser should be a multi-process application with proper security sandboxing. But Firefox isn’t — in fact, it has fallen behind Internet Explorer when it comes to these two important features.
Firefox 在某些方面仍旧是最好的浏览器。比如,如果您需要最强大的浏览器扩展框架,那非 Firefox 莫属。但我们希望 Firefox 在其他方面也能变得更有竞争力。在 2013 年,多进程架构和可靠的安全沙盒技术都是一个浏览器所需具备的能力,但 Firefox 却没有。事实上,在这两个重要特性上,Firefox 甚至还不如 Internet Explorer。
There was once a powerful browser known as the Mozilla suite. It was too big and bloated for its own good, so a group of developers decided to create a new, minimal browser from its core technologies. They called it Phoenix, and it evolved into the Firefox we know today. If Mozilla can’t turn Firefox into a modern browser because of all the legacy code getting in the way, perhaps we need a Phoenix 2.0.
我还记得以前有一个强大的浏览器叫做 Mozilla Suite,体积虽大但有自己的好处,因此开发者决定根据它的核心技术创造一个全新而又小巧的浏览器,他们称之为 Phoenix。它最终演变为今天我们所知道的 Firefox。假如因为这些遗留的代码妨碍了 Mozilla 将 Firefox 变成一个现代浏览器,也许我们需要一个 Phoenix 2.0。